package com.gitee.wsl.common.ui.graphics

import androidx.compose.runtime.Composable
import androidx.compose.ui.Modifier
import kotlinx.browser.window

@Composable
actual fun getDisplayMetrics(): DisplayMetrics = window.devicePixelRatio.let {
    val floatDensity = it.toFloat()
    DisplayMetrics(
        density = it.toFloat(),
        xdpi = floatDensity * 160f,
        ydpi = floatDensity * 160f,
    )
}

